package cn.com.infcn.spider.util;

import java.util.Map;
import java.util.Map.Entry;

import org.python.util.PythonInterpreter;

public class JythonFactory {

	public static PythonInterpreter newInstance(Map<String, Object> maps) {
		PythonInterpreter py = new PythonInterpreter();
		for (Entry<String, Object> entry : maps.entrySet()) {
			py.set(entry.getKey(), entry.getValue());
		}
		return py;
	}

	public static PythonInterpreter newInstance() {
		PythonInterpreter py = new PythonInterpreter();
		return py;
	}

}
